<script setup lang="ts">
import { usePlatformStore } from '@/store/modules/platform';

defineOptions({
  name: 'GlobalLogo'
});

interface Props {
  /** 是否显示 Title */
  showTitle?: boolean;
}

const { showTitle = true } = defineProps<Props>();

const { platformInfo } = usePlatformStore();
</script>

<template>
  <RouterLink to="/" class="w-full flex-center nowrap-hidden">
    <SystemLogo class="w-28px" />
    <h2 v-show="showTitle" class="pl-12px text-14px text-primary font-bold transition duration-300 ease-in-out">
      {{ platformInfo.systemName }}
    </h2>
  </RouterLink>
</template>

<style scoped></style>
